<!DOCTYPE html>
<html lang="zh-CN">
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <!-- 上述3个meta标签*必须*放在最前面，任何其他内容都*必须*跟随其后！ -->
    <title>TA的粉丝</title>

    <!-- Bootstrap -->
    <link href="css/bootstrap.min.css" rel="stylesheet">
    <link rel="stylesheet" type="text/css" href="css/css/styles.css" />
    <link href="css/css/top_bar.css" rel="stylesheet" type="text/css">
    <!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
    <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
    <!--[if lt IE 9]>
      <script src="http://cdn.bootcss.com/html5shiv/3.7.2/html5shiv.min.js"></script>
      <script src="http://cdn.bootcss.com/respond.js/1.4.2/respond.min.js"></script>
    <![endif]-->
  </head>
  <body>
    <div class="header">
      <div class="row" id="top_bar">
        <div class="fixed_div">  <!-- fixed_div -->
          <div class="webTitle">
            <a href="/index.html">
              <img src="image/art_logo.png">
            </a>
          </div>
          <div class="search">
            <img src="image/search.png">
            <input type="text" placeholder="搜索画室、标签">
          </div>
          <div class="switch-pages">
            <a href="/index.html"><span class="top_btn">首页</span></a>
            <a href="/Q&A.html"><span class="top_btn">问答</span></a>
            <a href="/gallery.html"><span class="top_btn">资料</span></a>
          </div>
          <div class="operation-btns">
            <span class="log_reg" data-toggle="modal" data-target="#logModal">登录</span>
            <span class="log_reg" data-toggle="modal" data-target="#regModal">注册</span>
            <div class="user">
              <div class="avatar_userName">
                <a href="/Info.html">
                  <div class="log_avatar">
                    <img src="image/emptyAvatar.jpg"> 
                  </div>  
                  <span class="userName">name</span>
                </a> 
              </div>

              <div class="hidden_first">
                <div class="triangle"></div>  
                <div class="user-list">
                  <div class="updateInfo" data-toggle="modal" data-target="#updateInfoModal">
                    <a href="/updateUserInfo.html">修改资料</a>
                  </div>
                  <div class="changePass" data-toggle="modal" data-target="#changePassModal">修改密码</div>
                  <div class="quit">退出</div>
                </div>
              </div>
            </div>
          </div> 
        </div>
      </div>
      <!-- logModal -->
      <div class="modal fade" id="logModal" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">

        <div class="modal-dialog">
          <div class="modal-content">
            <div class="closeModal" data-dismiss="modal">
              <img src="image/CLOSE.png">
            </div>
            <div class="input-line">
              <img src="image/email.png" class="account-img">
              <input type="text" id="logAccount" placeholder="输入账号"/>
            </div>
            <div class="error"></div>
            <div class="input-line">
              <img src="image/lock.png" class="password-img">
              <input type="password" id="logPassword" placeholder="输入密码"/>
            </div>           
            <div class="error"></div>

            <div class="submit-holder">
              <img class="main-submit" src="image/login.png">
            </div>
            <div class="other_login">
              <img src="image/weibo.jpg">
              <span>其它登录：</span>
            </div>
          </div>
        </div>        
      </div>

      <!-- regModal -->
      <div class="modal fade" id="regModal" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
        <div class="modal-dialog">
          <div class="modal-content">
            <div class="closeModal" data-dismiss="modal">
              <img src="image/CLOSE.png">
            </div>

            <div class="input-line">
              <div class="labels">
                <span>手机号码</span>
              </div>
              <input type="text" id="regPhone" class="short" placeholder="输入手机号码"/>
              <img class="getCode" src="image/getCode.png">
            </div>
            <div class="error"></div>
            <div class="input-line">
              <div class="labels">
                <span>验证码</span>
              </div>
              <input type="text" id="regCode" placeholder="输入手机验证码"/>
            </div>
            <div class="error"></div>
            <div class="input-line">
              <div class="labels">
                <span>密码</span>
              </div>
              <input type="password" id="regPassword" placeholder="输入密码"/>
            </div>           
            <div class="error"></div>
            <div class="input-line">
              <div class="labels">
                <span>密码</span>
              </div>
              <input type="password" id="regPassword2" placeholder="再次输入密码"/>
            </div>           
            <div class="error"></div>
            <div class="submit-holder">
              <img class="main-submit" src="image/reg.png">
            </div>
          </div>
        </div>        
      </div>

      <!-- changePassModal -->
      <div class="modal fade" id="changePassModal" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">

        <div class="modal-dialog">
          <div class="modal-content">

            <div class="input-line">
              <input type="password" id="oldPassword" placeholder="输入旧密码"/>
            </div>
            <div class="error"></div>
            <div class="input-line">
              <input type="password" id="changePassword1" placeholder="输入新密码"/>
            </div>           
            <div class="error"></div>
            <div class="input-line">
              <input type="password" id="changePassword2" placeholder="确认新密码"/>
            </div>           
            <div class="error"></div>

            <div class="submit-holder">
              <img class="quit" src="image/cancel.png" data-dismiss="modal">
              <img class="main-submit" src="image/confirm.png">
            </div>
          </div>
        </div>        
      </div>
    </div>
    <div class="container">
      <div class="row">
        <div class="col-md-8 col.xs-8 col-sm-8 col-lg-8 fansListContainer">
          <!--fansList-template-->

        </div>
        <div class="col-md-4 col-xs-4 col-sm-4 col-lg-4 ">
          <div class="socailInfoContainer">
            
          </div>
        </div>
      </div>
    </div>
    <!--粉丝列表-->
    <script id="fansList-template" type="text/x-handlebars-template">
    {{#if fan.length}}
    <ol class="breadcrumb">
      <li ><a href="#" id="otherInfoLink">主页</a></li>
      <li class="active">TA的粉丝</li>
    </ol>
    <ul class="userList">
      {{#each fan}}
      <li class="userItem" data-userId={{this._id}} data-utype={{this.uType}}>
        {{#if this.avatarUrl}}
          <img src={{this.avatarUrl}} alt="" class="userAvatar"/>
        {{else}}
          <img src="image/emptyAvatar.jpg" class="userAvatar">
        {{/if}}
        
        <h5>{{this.name}}</h5>
      </li>
      {{/each}}
    </ul>
    {{else}}
    <ol class="breadcrumb">
       <li ><a href="#" id="otherInfoLink">主页</a></li>
      <li class="active">TA的粉丝</li>
    </ol>
      <p>暂无粉丝</p>
    {{/if}}
    </script>
    <script id="userInfo-template" type="text/x-handlebars-template">
      <div class="socialInfo">
        <div class="row profile">
          <div class="col-md-12 col-xs-12 col-sm-12 col-lg-12">
            {{#if user.avatarUrl}}
              <img src={{user.avatarUrl}} alt="avator">
            {{else}}
              <img src="image/emptyAvatar.jpg" alt="avator">
            {{/if}}
            <p id="userName">{{user.name}}</p>
          </div>
        </div>
        <div class="row socialNum">
          <div style="float:left; width:50%;">
            <p style="border-right: 1px solid #DCDCDC">
              <span>{{user.fanNum}}</span></br>
              <a href="othersFans.html" id="fansLink">粉丝<a/>
            </p>
          </div>
          <div style="float:left; width: 50%; ">
            <p>
              <span>{{user.followNum}}</span></br>
              <a href="othersFollow.html" id="followLink">关注<a/>
            </p>
          </div>
        </div>
      </div>
      <div id="followBtnContainer">
        <button class="btn btn-primary btn-lg btn-block" id="followThisGuy" type="button">关注</button>
      </div>
    </script>

    <script src="js/thirdparty/require.js" data-main="js/othersFans"></script>

      <div class="footer">
        <div class="footerContent">
          <ul class="footerList">
            <li><a href="#">关于我们</a></li>
            <li><a href="#">联系我们</a></li>
            <li><a href="#">广告业务</a></li>
          </ul>
          <p class="icp">京备123号</p>
          <h2>美术帮</h2>
        </div>
      </div>

  </body>
</html>